package enviornment;

/**
 * Defines a weather report contains the time of the weather prediction 
 * and whether it is bad weather regarding to flooding.
 * @author Chunhui Li
 *
 */
public class Weather {
    private double floodProbability; // probability of flooding
	public boolean badWeather;//bad weather for flood
    private double timeOfWeather;
    
	public Weather() {
		timeOfWeather = 0.0;
		badWeather = false;
		floodProbability = 0.0;
		
	}
	public double getTime(){
		return timeOfWeather;
	}
	
	public boolean getBadWeather(){
		return badWeather;
	}
	
	public double getProbability(){
		return floodProbability;
	}
	
	public void setWeatherTime(double t){
		this.timeOfWeather = t;		
	}
	
	public void setBadWeather(boolean b){
		this.badWeather = b;
	}
	
	public void setProbability(double p){
		this.floodProbability = p;
	}
	
	public String toString(){
		String txt = "Weather: BadWeather is "+ badWeather +" at the time tick "+ timeOfWeather;
		return txt;
	}

}
